<!DOCTYPE html>
<html lang="zxx">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>FoodKa - Food Ordering, Delivery & Restuarent Template</title>

    <!--  js  -->
    <!-- all plugins here -->
    <script src="static/js/jquery.3.6.min.js"></script>
    <script src="static/js/jquery-ui.min.js"></script>
    <script src="static/js/bootstrap.min.js"></script>
    <script src="static/js/imageloded.min.js"></script>
    <script src="static/js/counterup.js"></script>
    <script src="static/js/waypoint.js"></script>
    <script src="static/js/magnific.min.js"></script>
    <script src="static/js/isotope.pkgd.min.js"></script>
    <script src="static/js/nice-select.min.js"></script>
    <script src="static/js/fontawesome.min.js"></script>
    <script src="static/js/owl.min.js"></script>
    <script src="static/js/slick-slider.min.js"></script>
    <script src="static/js/wow.min.js"></script>
    <script src="static/js/tweenmax.min.js"></script>
    <!-- main js  -->
    <script src="static/js/main.js"></script>
    <script type="text/javascript" src="static/js/include.js"></script>
    <script src="static/js/getParameter.js"></script>
    <!-- Stylesheet -->
    <link rel="stylesheet" href="static/css/animate.min.css">
    <link rel="stylesheet" href="static/css/bootstrap.min.css">
    <link rel="stylesheet" href="static/css/magnific.min.css">
    <link rel="stylesheet" href="static/css/nice-select.min.css">
    <link rel="stylesheet" href="static/css/owl.min.css">
    <link rel="stylesheet" href="static/css/slick-slide.min.css">
    <link rel="stylesheet" href="static/css/fontawesome.min.css">
    <link rel="stylesheet" href="static/css/remixicon.css">
    <link rel="stylesheet" href="static/css/style.css">
    <link rel="stylesheet" href="static/css/responsive.css">

    <!--Google Fonts-->
    <link href="static/css/css2.css" rel="stylesheet">

    <script>
        $(function () {
            var add_id = getParameter("add_id");
            $.post("/Pizza_war_exploded/Address/findCheckedAddress",
                {add_id:add_id},
                function(data) {
                    $("#add_id").val(add_id);
                    $("#name").val(data.name);
                    $("#telephone").val(data.telephone);
                    $("#address").val(data.address_detail);
                    if (data.sex == '男'){
                        $("#sex1").attr("checked", "checked");
                    }else if (data.sex == '女'){
                        $("#sex2").attr("checked", "checked");
                    }
                },"json");
        });
        function saveClick() {
            $.post("/Pizza_war_exploded/Address/updateAddress",
                $("#saveForm").serialize(),
                function(data) {
                    if (data.flag) {
                        location.href = "/Pizza_war_exploded/address-list.html";
                    }
                },"json");
        }
        function cancelClick() {
            history.back();
        }
    </script>
</head>
<body class='sc5'>
<!-- preloader area start -->
<div class="preloader" id="preloader">
    <div class="preloader-inner">
        <div id="wave1">
        </div>
        <div class="spinner">
            <div class="dot1"></div>
            <div class="dot2"></div>
        </div>
    </div>
</div>
<!-- preloader area end -->
<!-- search popup area start -->
<div class="body-overlay" id="body-overlay"></div>
<div class="td-search-popup" id="td-search-popup">
    <form action="index.html" class="search-form">
        <div class="form-group">
            <input type="text" class="form-control" placeholder="Search.....">
        </div>
        <button type="submit" class="submit-btn"><i class="fa fa-search"></i></button>
    </form>
</div>
<!-- //. search Popup -->

<!-- navbar start -->
<div id="header"></div>
<!-- navbar end -->

<!-- bredcrumb Area Start-->
<section class="breadcrumb-area">
    <div class="banner-bg-img"></div>
<!--    <div class="banner-shape-1"><img src="static/picture/shape-1.png" alt="img"></div>-->
<!--    <div class="banner-shape-2"><img src="static/picture/shape-2.png" alt="img"></div>-->
    <div class="container">
        <div class="row justify-content-center">
            <div class="col-lg-8 align-self-center">
                <div class="banner-inner text-center">
                    <h3>Address
                    </h3>
                    <h1>Your Address Detail
                    </h1>
                    <nav aria-label="breadcrumb">
                        <ul class="breadcrumb">
                            <li class="breadcrumb-item"><a href="javascript:;">Home</a></li>
                            <li class="breadcrumb-item active" aria-current="page">Detail</li>
                        </ul>
                    </nav>
                </div>
            </div>
        </div>
    </div>
</section>
<!-- bredcrumb Area End -->

<!-- checkout area start -->
<div class="checkout-area pd-top-120 pd-bottom-120">
    <div class="container">
        <div class="row justify-content-center">
            <div class="col-lg-7">
                <div class="bill-payment-wrap">
                    <h5>地址详情</h5>
                    <form id="saveForm" class="default-form-wrap style-2">
                        <div class="row">
                            <div class="col-md-6">
                                <label>收货人</label>
                                <div class="single-input-wrap">
                                    <input type="hidden" id="add_id" name="id">
                                    <input id="name" name="name" type="text" class="form-control" placeholder="">
                                </div>
                            </div>
                            <div class="col-md-6">
                                <label>手机号</label>
                                <div class="single-input-wrap">
                                    <input id="telephone" name="telephone" type="text" class="form-control" placeholder="">
                                </div>
                            </div>
                            <div class="col-md-12">
                                <label>性别</label>
                                <div class="form-check-wrap">
<!--                                    <input id="sex" type="text" class="form-control" placeholder="">-->
                                    <input type="radio" id="sex1" name="sex" value="男"> 男
                                    <input type="radio" id="sex2" name="sex" value="女"> 女
                                </div>
                            </div>
                            <div class="col-md-12"></br>
                                <label>收获地址</label>
                                <div class="single-input-wrap">
                                    <input id="address" name="address" type="text" class="form-control" placeholder="">
                                </div>
                            </div>
                        </div>
                        <a id="saveButton" class="btn btn-secondary w-100" onclick="saveClick()">保存</a>
                        <a class="btn btn-secondary w-100" onclick="cancelClick()">取消保存</a>
                    </form>
                </div>
            </div>
            <!--<div class="col-lg-5">
                <div class="order-area">
                    <h5 class="title">你的订单</h5>
                    <div class="order-product">
                        <div class="thumb">
                            <img src="static/picture/011.png" alt="img">
                        </div>
                        <div class="details">
                            <h6>All Season Gulliver Pizza</h6>
                            <ul>
                                <li><span>Select Size: </span>Large</li>
                                <li><span>Select Crust: </span>Double Crust</li>
                            </ul>
                        </div>
                    </div>
                    <ul class="amount">
                        <li>小计<span>$50.00</span></li>
                        <li class="total">总价<span>$50.00</span></li>
                    </ul>
                    <div class="peyment-method">
                        <h6>付款方式</h6>
                        <ul class="card-area">
                            <li>
                                <div class="form-check">
                                    <input class="form-check-input" type="radio" name="flexRadioDefault" id="flexRadioDefault1">
                                    <label class="form-check-label" for="flexRadioDefault1">
                                    </label>
                                </div>
                                <div class="details">
                                    <h6>支付宝 <img src="static/picture/zfb.png" alt="img"></h6>
                                    <p>支付宝,全球领先的独立第三方支付平台,致力于为广大用户提供安全快速的电子支付</p>
                                </div>
                            </li>
                            <li>
                                <div class="form-check">
                                    <input class="form-check-input" type="radio" name="flexRadioDefault" id="flexRadioDefault2">
                                    <label class="form-check-label" for="flexRadioDefault2">
                                    </label>
                                </div>
                                <div class="details">
                                    <h6>微信 <img src="static/picture/wx.png" alt="img"></h6>
                                    <p>微信支付是腾讯公司的支付业务品牌,微信支付商户平台支持线下场所、小程序等经营场景快速接入微信支付</p>
                                </div>
                            </li>
                        </ul>
                    </div>
                    <a class="btn btn-secondary w-100" href="#">立即下单</a>
                </div>
            </div>-->
        </div>
    </div>
</div>
<!-- checkout area end -->

<!-- footer area start -->
<div id="footer"></div>
<!-- footer area end -->

<!-- back-to-top end -->
<div class="back-to-top">
    <span class="back-top"><i class="fas fa-angle-double-up"></i></span>
</div>

</body>
</html>